<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ include file="/common/taglibs.jsp"%>
<%@ include file="/common/meta.jsp"%>
<!DOCTYPE html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<script type="text/javascript" src="${res}/js/proposal/irisPrpPrepare.js"></script>
<title>项目汇总数据</title>
<style type="text/css">
.button_orange { 
	height:25px; font-size:12px; color:#cc3300; border:1px #cc9933 solid; 
	background:url(${res}/images/button_orange.gif); padding:0 15px; *padding:0 10px;
	_padding:0 10px; cursor: pointer;
}
.t_css td {
	border: 1px solid #A1C0DC;
}
</style>
</head>
<body>
<script type="text/javascript">
function PrintToExcel()
{
		location=location.href+"type=excel";
}
</script>
	<div id="content">
<c:if test="${param.type!= 'excel'}">
		<table id="tbAction" cellspacing="0" cellpadding="0" width="100%" border="0"  >
				<tr>
					<td colspan=7 align="center">
						<input type="button" id="print" value="输出Excel" class="button" onclick="PrintToExcel()">
						<input name="Submit2" type="button" class="button"  value="关闭"  onclick="parent.tb_remove(); "/>
					</td>
				</tr>
			</table>
</c:if>
    <p align="center"><span style="font-size:20px;font-weight:bold;"><c:if test="${not empty param.statYear}">${param.statYear}年度</c:if>${rpt_name}</span></p>
	<table  class="table01" width="100%" border="0" cellpadding="0" id="basicInfo" cellspacing="1" style="border: 1px solid #A1C0DC">
		<tr>
		       <!-- 显示表头 -->
		       <th nowrap width="40px">序号</th>
			   <c:forEach items="${listkey }" var="key" varStatus="status">
			     <th <c:if test="${fn:indexOf(key,'_CLOB')!=-1 }"> width='300'  </c:if><c:if test="${fn:indexOf(key,'_CLOB')==-1 }"> width="100" </c:if> nowrap ><c:out value="${headermap[key]}" /></th>
		       </c:forEach>	        
		</tr>
		
		<!-- 显示数据 -->
		<c:forEach var="vo" items="${data}" varStatus="status">
			<tr>
			<!-- 按照key的排列顺序取出数据 -->
			
			<!-- vnd.ms-excel.numberformat:@ 是为了解决excel导出时数据格式化问题,防止长串数字被表示为科学技术法 -->
			
			 <td style="vnd.ms-excel.numberformat:@" align="center"  width='40px' nowrap>${status.index+1 }</td>
			 <c:forEach items="${listkey }" var="key">
			 	<!-- AAC列表示单位名称列 -->
	              <td style="vnd.ms-excel.numberformat:@" <c:choose><c:when test="${fn:indexOf(key,'_CLOB')!=-1 || key=='AAB'}">align="left"  width='300' </c:when><c:when test="${fn:indexOf(key,'_CLOB')!=-1 || key=='AAC'}">align="left"  width='300' </c:when><c:when test="${fn:indexOf(key,'_CLOB')!=-1 || key=='AAD'}">align="left"  width='300' </c:when><c:otherwise>align="center"  width='300'</c:otherwise> </c:choose> >
			      <c:if test="${vo[key] == null}">&nbsp;</c:if>
			      <c:if  test="${vo[key]  != null }">
			                  ${vo[key] } 
			      </c:if>
		          </td>			  
			</c:forEach>
			</tr>
	 	</c:forEach>		
		
	</table>
	</div>
</body>
</html>